﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using WindowsTheme.Helper;

namespace WindowsTheme
{
    public partial class ImgAlert : Form
    {
        public ImgAlert()
        {
          
           
            InitializeComponent();
           
        }
        public ImgAlert(String MessageText, String ImgPath)
        {
            InitializeComponent();
            label1.Text = MessageText;
            Console.WriteLine(ImgPath);
            pictureBox1.SizeMode = PictureBoxSizeMode.Zoom;
            this.pictureBox1.Image = Image.FromFile(ImgPath);
            this.Icon = Icon.ExtractAssociatedIcon(Application.ExecutablePath);
        }
        private void button1_Click(object sender, EventArgs e)
        {
            StaticValue.JumpFlag1 = false;
            WindowExit();
        }

        private void WindowExit()
        {
            pictureBox1.Dispose();
            this.Close();
        }

        private void button2_Click(object sender, EventArgs e)
        {
            StaticValue.JumpFlag1 = true;
            WindowExit();
        }
    }
}
